<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>

<title></title>
<link href="../../css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../../js/main.js"></script>
<script type="text/javascript" src="../../js/myjs.js"></script>
<script type="text/javascript">
function ckoldpwd(){
	var oldpwd=document.getElementById("oldpwd").value;
	if(oldpwd==""){
		document.getElementById("s1").innerHTML="与原密码不一致";
		document.getElementById("s1").style.color="red";
		return false;
	}
	document.getElementById("s1").innerHTML="";
	return true;
}
function cknewpwd(){
	var newpwd=document.getElementById("newpwd").value;
	if(newpwd==""){
		document.getElementById("s2").innerHTML="请输入新密码";
		document.getElementById("s2").style.color="red";
		return false;
	}else{
		
		if(newpwd.length<6){
			document.getElementById("s2").innerHTML="弱";
			document.getElementById("s2").style.color="red";
		}else if(newpwd.length>6&&newpwd.length<10){
			document.getElementById("s2").innerHTML="中";
			document.getElementById("s2").style.color="red";
		}else if(newpwd.length>10){
			document.getElementById("s2").innerHTML="√";
			document.getElementById("s2").style.color="red";
		}
		return true;
		
	}
	
	
	
	
}


function ckrenewpwd(){
	
	var newpwd=document.getElementById("newpwd").value;
	var renewpwd=document.getElementById("renewpwd").value;
	
	if(renewpwd==""){
		document.getElementById("s3").innerHTML="请再次输入新密码";
		document.getElementById("s3").style.color="red";
		return false;
	}
	else if(newpwd!=renewpwd){
		alert("两次密码输入不一致");
		return false;
	}
	document.getElementById("s3").innerHTML="";
	if(confirm('确认修改？')){}
	return true;
	
}


</script>
</head>
<body>
<table width="100%" height="100%" border="0" cellspacing="0" cellpadding="3">
  <tr>
    <td style="height:25px; background-color:#f3f3f3; font-weight:bold" valign="top">
    &nbsp;&nbsp;&nbsp;&nbsp;当前位置：
    <img src="../../images/arrow.gif" align="absmiddle">&nbsp;&nbsp;soda创业教育平台&nbsp;&nbsp;
    <img src="../../images/arrow.gif" align="absmiddle">&nbsp;&nbsp;后台管理&nbsp;&nbsp;
    <img src="../../images/arrow.gif" align="absmiddle">&nbsp;&nbsp;密码修改</td>
  </tr>
  <tr>
    <td style="height:34px; background-image:url(../../images/main_header.gif); border-bottom:1px solid #cfd8e0; padding:0px">
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="20" height="34"><img src="../../images/main_headerL.gif" width="20" height="34"></td>
          <td style="color:#90c8e8;"><img src="../../images/icon_card.gif" width="16" height="16" align="absmiddle">&nbsp;&nbsp;<strong>修改个人密码</strong></td>
       
        </tr>
    </table></td>
  </tr>
  <tr>
    <td style="height:30px; background-color:#bddbff; border-bottom:1px solid #cfd8e0;"><table width="100%" border="0" cellpadding="3" cellspacing="1" class="table1">
      <TR>
        
	   </TR>
    </table></td>
  </tr>
  <tr>
    <td height="100%" valign="top">
    <div style="overflow:auto;height:100%; width:100%">
	<form action="<%=request.getContextPath() %>/UserServlet?param=editPWD" method="post" onsubmit="return check();">
      <table width="100%" border="0" cellpadding="3" cellspacing="1" class="table1">
        <tr >
			<td style="text-align:right">请输入旧密码：</td><td style="width: 700px"><input type="password" id="oldpwd" onblur="ckoldpwd()" name="oldpwd"><span  id="s1" style="color:red;">与原密码不一致</span></td>
		</tr>
		 <tr>
			<td style="text-align:right">请输入新密码：</td><td><input type="password" id="newpwd" onblur="cknewpwd()" name="newpwd"><span id="s2"></span></td>
		</tr>
		 <tr>
			<td style="text-align:right">请输入重复密码：</td><td><input type="password" id="renewpwd" onblur="ckrenewpwd()" name="renewpwd"><span id="s3" style="color: red;">两次密码输入不一致</span></td>
		</tr>
		<tr>
			<td style="text-align:right"></td><td ><input type="submit" value="提交" >&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
			<input type="button" value="返回" onClick="javascript:window.history.back();"></td>
		</tr>
      </table>
    </form>  
    </div>
  </td>
  </tr>
</table>
</body>
</html>